package com.gis.filter;

import java.io.IOException;

import javax.servlet.*;

import com.gis.util.Constant;

public class EncodingFilter implements Filter {

	@Override
	public void init(FilterConfig arg0) throws ServletException {

	}

	@Override
	public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain)
			throws IOException, ServletException {
		request.setCharacterEncoding(Constant.UTF_8);
		response.setCharacterEncoding(Constant.UTF_8);
		chain.doFilter(request, response);
	}

	@Override
	public void destroy() {

	}

}
